
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<HTML>

<HEAD>
   <TITLE>unitim_c</TITLE>
</HEAD>

<BODY style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">
<A name="TOP"></A>

<table style="text-align: left; margin-left: auto; margin-right: auto; width: 800px;"
 border="0" cellpadding="5" cellspacing="2">
  <tbody>
    <tr>
      <td style="background-color: rgb(153, 153, 153); vertical-align: middle; text-align: center;">
      <div align="right"> 
      <small><small><a href="index.html">Index Page</a></small></small>
      </div>
      <b>unitim_c</b> </td>
    </tr>

    <tr>
      <td style="vertical-align: top;">

<small><div align="center">
<A HREF="index.html#A">A</A>&nbsp;
<A HREF="index.html#B">B</A>&nbsp;
<A HREF="index.html#C">C</A>&nbsp;
<A HREF="index.html#D">D</A>&nbsp;
<A HREF="index.html#E">E</A>&nbsp;
<A HREF="index.html#F">F</A>&nbsp;
<A HREF="index.html#G">G</A>&nbsp;
<A HREF="index.html#H">H</A>&nbsp;
<A HREF="index.html#I">I</A>&nbsp;
<A HREF="index.html#J">J</A>&nbsp;
<A HREF="index.html#K">K</A>&nbsp;
<A HREF="index.html#L">L</A>&nbsp;
<A HREF="index.html#M">M</A>&nbsp;
<A HREF="index.html#N">N</A>&nbsp;
<A HREF="index.html#O">O</A>&nbsp;
<A HREF="index.html#P">P</A>&nbsp;
<A HREF="index.html#Q">Q</A>&nbsp;
<A HREF="index.html#R">R</A>&nbsp;
<A HREF="index.html#S">S</A>&nbsp;
<A HREF="index.html#T">T</A>&nbsp;
<A HREF="index.html#U">U</A>&nbsp;
<A HREF="index.html#V">V</A>&nbsp;
<A HREF="index.html#W">W</A>&nbsp;
<A HREF="index.html#X">X</A>&nbsp;
</div></small>
       <br>
       <table style="text-align: left; width: 60%; margin-left: auto; margin-right: auto;"
       border="0" cellspacing="2" cellpadding="2">
        <tbody>
          <tr>
            <td style="width: 50%; text-align: center;">
            <small>
              <a href="#Procedure">Procedure<br></a>
              <a href="#Abstract">Abstract<br></a>
              <a href="#Required_Reading">Required_Reading<br></a>
              <a href="#Keywords">Keywords<br></a>
              <a href="#Brief_I/O">Brief_I/O<br></a>
              <a href="#Detailed_Input">Detailed_Input<br></a>

              </small>
              </td>
              <td style="vertical-align: top; width: 50%; text-align: center;">
              <small>               <a href="#Detailed_Output">Detailed_Output<br></a>
              <a href="#Parameters">Parameters<br></a>
              <a href="#Exceptions">Exceptions<br></a>
              <a href="#Files">Files<br></a>
              <a href="#Particulars">Particulars<br></a>
              <a href="#Examples">Examples<br></a>

              </small>
              </td>
              <td style="vertical-align: top; width: 50%; text-align: center;">
              <small>               <a href="#Restrictions">Restrictions<br></a>
              <a href="#Literature_References">Literature_References<br></a>
              <a href="#Author_and_Institution">Author_and_Institution<br></a>
              <a href="#Version">Version<br></a>
              <a href="#Index_Entries">Index_Entries<br></a>
             </small>
            </td>
          </tr>
        </tbody>
</table>

<h4><a name="Procedure">Procedure</a></h4>
<PRE>
   SpiceDouble unitim_c ( SpiceDouble        epoch,
                          ConstSpiceChar   * insys,
                          ConstSpiceChar   * outsys )

</PRE>
<h4><a name="Abstract">Abstract</a></h4>
<PRE>
   Transform time from one uniform scale to another.  The uniform
   time scales are TAI, TDT, TDB, ET, JED, JDTDB, JDTDT.
</PRE>
<h4><a name="Required_Reading">Required_Reading</a></h4>
<PRE>
   <a href="../req/time.html">TIME</a>
</PRE>
<h4><a name="Keywords">Keywords</a></h4>
<PRE>
   TIME
   CONVERSION
   UTILITY


</PRE>
<h4><a name="Brief_I/O">Brief_I/O</a></h4>
<PRE>
   Variable  I/O  Description
   --------  ---  --------------------------------------------------
   epoch      I   An epoch to be converted.
   insys      I   The time scale associated with the input epoch.
   outsys     I   The time scale associated with the function value.

   The function returns the d.p. in outsys that is equivalent to the
   epoch on the insys time scale.
</PRE>
<h4><a name="Detailed_Input">Detailed_Input</a></h4>
<PRE>
   epoch      is an epoch relative to the insys time scale.

   insys      is a time scale.  Acceptable values are:

              &quot;TAI&quot;     International Atomic Time.
              &quot;TDB&quot;     Barycentric Dynamical Time.
              &quot;TDT&quot;     Terrestrial Dynamical Time.
              &quot;ET&quot;      Ephemeris time (in the SPICE system, this is
                        equivalent to TDB).
              &quot;JDTDB&quot;   Julian Date relative to TDB.
              &quot;JDTDT&quot;   Julian Date relative to TDT.
              &quot;JED&quot;     Julian Ephemeris date (in the SPICE system
                        this is equivalent to JDTDB).

              The routine is not sensitive to the case of the
              characters in insys;  &quot;tai&quot; &quot;Tai&quot; and &quot;TAI&quot; are
              all equivalent from the point of view of this routine.

   outsys     is the time scale to which epoch should be converted.
              Acceptable values are the same as for insys.  The
              routine is not sensitive to the case of outsys.
</PRE>
<h4><a name="Detailed_Output">Detailed_Output</a></h4>
<PRE>
   The function returns the time in the system specified by outsys
   that is equivalent to the epoch in the insys time scale.
</PRE>
<h4><a name="Parameters">Parameters</a></h4>
<PRE>
   None.
</PRE>
<h4><a name="Exceptions">Exceptions</a></h4>
<PRE>
   1) The kernel pool must contain the variables:

         &quot;DELTET/DELTA_T_A&quot;
         &quot;DELTET/K&quot;
         &quot;DELTET/EB&quot;
         &quot;DELTET/M&quot;

      If these are not present, the error SPICE(MISSINGTIMEINFO)
      will be signalled.  (These variables are typically inserted
      into the kernel pool by loading a leapseconds kernel with
      the SPICE routine <a href="furnsh_c.html">furnsh_c</a>.)

   2) If the names of either the input or output time types are
      unrecognized, the error SPICE(BADTIMETYPE) will be signalled.

   4) The error SPICE(EMPTYSTRING) is signalled if either input
      string does not contain at least one character, since an
      empty input string cannot be converted to a Fortran-style string.
      
   5) The error SPICE(NULLPOINTER) is signalled if either input string
      pointer is null.
</PRE>
<h4><a name="Files">Files</a></h4>
<PRE>
   None.
</PRE>
<h4><a name="Particulars">Particulars</a></h4>
<PRE>
   We use the term uniform time scale to refer to those
   representations of time that are numeric (each epoch is
   represented by a number) and additive.  A numeric time
   system is additive if given the representations, E1 and E2,
   of any pair of successive epochs, the time elapsed between
   the epochs is given by E2 - E1.

   Given an epoch in one of the uniform time scales
   specified by insys, the function returns the equivalent
   representation in the scale specified by outsys.  A list
   of the recognized uniform time scales is given in the
   detailed input for insys.
</PRE>
<h4><a name="Examples">Examples</a></h4>
<PRE>
   To convert an epoch with respect to the International Atomic
   Time (TAI) scale to ET (Barycentric Dynamical Time), make the
   following assignment.

         et = <b>unitim_c</b> ( tai, &quot;TAI&quot;, &quot;ET&quot; );
</PRE>
<h4><a name="Restrictions">Restrictions</a></h4>
<PRE>
   The appropriate variable must be loaded into the SPICE kernel pool
   (normally by loading a leapseconds kernel with <a href="furnsh_c.html">furnsh_c</a>) prior to
   calling this routine.
</PRE>
<h4><a name="Literature_References">Literature_References</a></h4>
<PRE>
   None.
</PRE>
<h4><a name="Author_and_Institution">Author_and_Institution</a></h4>
<PRE>
   H.A. Neilan    (JPL)
   W.L. Taber     (JPL)
</PRE>
<h4><a name="Version">Version</a></h4>
<PRE>
   -CSPICE Version 1.1.1, 14-AUG-2006   (EDW)

      Replace mention of <a href="ldpool_c.html">ldpool_c</a> with <a href="furnsh_c.html">furnsh_c</a>.

   -CSPICE Version 1.1.0, 08-FEB-1998 (NJB)

      Re-implemented routine without dynamically allocated, temporary 
      strings.   
 
   -CSPICE Version 1.0.0, 25-OCT-1997   (EDW)
</PRE>
<h4><a name="Index_Entries">Index_Entries</a></h4>
<PRE>
   Transform between two uniform numeric time systems
   Transform between two additive numeric time systems
   Convert one uniform numeric time system to another
   Convert one additive numeric time system to another
</PRE>
<h4>Link to routine unitim_c source file <a href='../../../src/cspice/unitim_c.c'>unitim_c.c</a> </h4>

      </td>
    </tr>
  </tbody>
</table>

   <pre>Wed Jun  9 13:05:32 2010</pre>

</body>
</html>

